using SqlSugar;
using System;
using System.Drawing;

namespace WinformDevelopFrame.Entity
{
    ///<summary>
    ///
    ///</summary>
    [SugarTable("sysmenu")]
    public partial class sysmenu
    {
        public sysmenu()
        {


        }
        /// <summary>
        /// Id
        /// </summary>   
        [SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
        [ModelBindControl("Id")]
        public int Id { get; set; }
        /// <summary>
        /// 数据ID
        /// </summary>   
        [ModelBindControl("BId")]
        public int BId { get; set; }
        /// <summary>
        /// 父ID
        /// </summary>   
        [ModelBindControl("PId")]
        public int PId { get; set; }
        /// <summary>
        /// 菜单名称
        /// </summary>   
        [ModelBindControl("MenuText")]
        public string MenuText { get; set; }
        /// <summary>
        /// 菜单编码
        /// </summary>   
        [ModelBindControl("MenuCode")]
        public string MenuCode { get; set; }
        /// <summary>
        /// 菜单图标
        /// </summary>   
        [ModelBindControl("MenuIcon")]
        public string MenuIcon { get; set; }

        /// <summary>
        /// 菜单图标
        /// </summary>
        [SugarColumn(IsIgnore = true)]
        public Image Icon {
            get
            {
                if (!string.IsNullOrEmpty(MenuIcon))
                {
                    return Image.FromFile(MenuIcon);
                }

                return null;
            }}
        /// <summary>
        /// 菜单类型
        /// </summary>   
        [ModelBindControl("MenuType")]
        public string MenuType { get; set; }
        /// <summary>
        /// 菜单地址
        /// </summary>   
        [ModelBindControl("MenuDll")]
        public string MenuDll { get; set; }
        /// <summary>
        /// 是否扩展开发
        /// </summary>   
        [ModelBindControl("IsExtendDevelop")]
        public bool IsExtendDevelop { get; set; }
        /// <summary>
        /// 菜单类名
        /// </summary>   
        [ModelBindControl("MenuName")]
        public string MenuName { get; set; }
        /// <summary>
        /// 是否通用功能
        /// </summary>   
        [ModelBindControl("IsPublicFunction")]
        public bool IsPublicFunction { get; set; }
        /// <summary>
        /// 创建人
        /// </summary>   
        [ModelBindControl("CreateUserId")]
        public int CreateUserId { get; set; }
        /// <summary>
        /// 创建时间
        /// </summary>   
        [ModelBindControl("CreateTime")]
        public DateTime CreateTime { get; set; }
        /// <summary>
        /// 修改人
        /// </summary>   
        [ModelBindControl("UpdateUserId")]
        public int UpdateUserId { get; set; }
        /// <summary>
        /// 修改时间
        /// </summary>   
        [ModelBindControl("UpdateTime")]
        public DateTime UpdateTime { get; set; }
        /// <summary>
        /// 备注
        /// </summary>   
        [ModelBindControl("Remark")]
        public string Remark { get; set; }

        /// <summary>
        /// 排序
        /// </summary>   
        [ModelBindControl("OrderNo")]
        public int OrderNo { get; set; } = 1;

        /// <summary>
        /// 显示方式
        /// </summary>   
        [ModelBindControl("ShowType")]
        public string ShowType { get; set; } = "TabShow";
    }
}
